<!DOCTYPE html>

<html lang="zh-CN">

<head>

    <meta charset="UTF-8">

    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <title><?php echo SITE_NAME; ?></title>

    <style>

        * {

            margin: 0;

            padding: 0;

            box-sizing: border-box;

            font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;

        }

        

        body {

            background-color: #f5f5f5;

            color: #333;

            line-height: 1.6;

        }

        

        .container {

            max-width: 1200px;

            margin: 0 auto;

            padding: 0 15px;

        }

        

        header {

            background: linear-gradient(135deg, #ff9a9e 0%, #fad0c4 100%);

            color: white;

            padding: 20px 0;

            box-shadow: 0 2px 10px rgba(0,0,0,0.1);

        }

        

        .header-content {

            display: flex;

            justify-content: space-between;

            align-items: center;

        }

        

        .logo h1 {

            font-size: 28px;

            font-weight: bold;

        }

        

        .logo p {

            font-size: 14px;

            opacity: 0.9;

        }

        

        nav ul {

            display: flex;

            list-style: none;

        }

        

        nav ul li {

            margin-left: 20px;

        }

        

        nav ul li a {

            color: white;

            text-decoration: none;

            padding: 5px 10px;

            border-radius: 3px;

            transition: background 0.3s;

        }

        

        nav ul li a:hover {

            background: rgba(255,255,255,0.2);

        }

        

        .apps-grid {

            display: grid;

            grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));

            gap: 20px;

            margin: 30px 0;

        }

        

        .app-card {

            background: white;

            border-radius: 10px;

            padding: 20px;

            box-shadow: 0 3px 15px rgba(0,0,0,0.1);

            transition: transform 0.3s, box-shadow 0.3s;

        }

        

        .app-card:hover {

            transform: translateY(-5px);

            box-shadow: 0 5px 20px rgba(0,0,0,0.15);

        }

        

        .app-icon {

            width: 60px;

            height: 60px;

            border-radius: 15px;

            object-fit: cover;

            margin-bottom: 15px;

        }

        

        .app-name {

            font-size: 18px;

            font-weight: bold;

            margin-bottom: 10px;

        }

        

        .app-version {

            color: #666;

            font-size: 12px;

            margin-bottom: 10px;

        }

        

        .app-description {

            color: #555;

            font-size: 14px;

            margin-bottom: 15px;

            display: -webkit-box;

            -webkit-line-clamp: 2;

            -webkit-box-orient: vertical;

            overflow: hidden;

        }

        

        .btn {

            display: inline-block;

            padding: 8px 16px;

            background: linear-gradient(135deg, #ff9a9e 0%, #fad0c4 100%);

            color: white;

            text-decoration: none;

            border-radius: 5px;

            border: none;

            cursor: pointer;

            transition: opacity 0.3s;

        }

        

        .btn:hover {

            opacity: 0.9;

        }

        

        .btn-secondary {

            background: #6c757d;

        }

        

        .btn-danger {

            background: #dc3545;

        }

        

        .form-group {

            margin-bottom: 20px;

        }

        

        .form-group label {

            display: block;

            margin-bottom: 5px;

            font-weight: bold;

        }

        

        .form-control {

            width: 100%;

            padding: 10px;

            border: 1px solid #ddd;

            border-radius: 5px;

            font-size: 14px;

        }

        

        textarea.form-control {

            min-height: 100px;

            resize: vertical;

        }

        

        .login-container {

            max-width: 400px;

            margin: 50px auto;

            background: white;

            padding: 30px;

            border-radius: 10px;

            box-shadow: 0 5px 15px rgba(0,0,0,0.1);

        }

        

        .alert {

            padding: 10px 15px;

            border-radius: 5px;

            margin-bottom: 20px;

        }

        

        .alert-error {

            background: #f8d7da;

            color: #721c24;

            border: 1px solid #f5c6cb;

        }

        

        .disclaimer {

            background: #fff3cd;

            border: 1px solid #ffeaa7;

            border-radius: 5px;

            padding: 15px;

            margin: 20px 0;

            font-size: 14px;

        }

        

        .disclaimer h3 {

            color: #856404;

            margin-bottom: 10px;

        }

        

        .disclaimer ul {

            padding-left: 20px;

        }

        

        .disclaimer li {

            margin-bottom: 5px;

        }
     

    </style>
 

</head>

<body>

    <header>

        <div class="container">

            <div class="header-content">

                <div class="logo">

                    <h1><?php echo SITE_NAME; ?></h1>

                    <p>发现优质手机应用</p>

                </div>

                <nav>

                    <ul>

                        <li><a href="index.php">首页</a></li>

                        <?php if (isLoggedIn()): ?>

                            <li><a href="admin.php">后台管理</a></li>

                            <li><a href="action/logout.php">退出</a></li>

                        <?php else: ?>

                            <li><a href="login.php">管理员登录</a></li>

                        <?php endif; ?>

                    </ul>

                </nav>

            </div>

        </div>

    </header>

    

    <div class="container">